{yun:}include file="$comstyle/header.htm"{/yun}
<div class="w1000">
	<div class="admin_mainbody"> 
		{yun:}include file="$comstyle/left.htm"{/yun}
		<div class=right_box>
			<div class=admincont_box>
				
				<div class="yun_com_tit">
					<span class="yun_com_tit_s">职位管理</span>
				</div>
				
				<div class="job_list_tit">
					<ul class="">
						<li {yun:}if $smarty.get.w=="1"{/yun} class="job_list_tit_cur"{yun:}/if{/yun}>
							<a href="index.php?c=job&w=1">招聘中的职位</a>
						</li>
						
						<li {yun:}if $smarty.get.w=="0"{/yun} class="job_list_tit_cur"{yun:}/if{/yun}>
							<a href="index.php?c=job&w=0">待审核职位</a>
						</li>
						
						<li {yun:}if $smarty.get.w=="3"{/yun} class="job_list_tit_cur"{yun:}/if{/yun}>
							<a href="index.php?c=job&w=3">未通过职位</a>
						</li>
						
						<li {yun:}if $smarty.get.w=="2"{/yun} class="job_list_tit_cur"{yun:}/if{/yun}>
							<a href="index.php?c=job&w=2">过期职位</a>
						</li>
						
						<li {yun:}if $smarty.get.w=="4"{/yun} class="job_list_tit_cur"{yun:}/if{/yun}>
							<a href="index.php?c=job&w=4">已下架职位</a>
						</li>
						
						<li {yun:}if $smarty.get.w=="5"{/yun} class="job_list_tit_cur"{yun:}/if{/yun}>
							<a href="index.php?c=job&w=5">所有职位</a>
						</li>
					</ul>
				</div>

				<div class="com_body">
				
					<div class="clear"></div>
					{yun:}if $audit>0{/yun}
					<div class="admin_new_tip mt20">
						<div class="admin_new_tit"><i class="admin_new_tit_icon"></i>操作提示</div>
						<div class="admin_new_tip_list_cont">
							<div class="admin_new_tip_list">
								你有 <font color="#FF0000">{yun:}$audit{/yun}</font> 个待审核职位，我们将在24小时内审核，如需马上审核，请联系客服：{yun:}$config.sy_webtel{/yun} 
							</div>
						</div>
					</div>
					{yun:}/if{/yun}
					
					<div class="clear"></div>
					
					<div class="joblist_search">
						<form action="index.php" method="get">
							<div class="joblist_search_box">
								<input name="c" type="hidden" value="job">
								<input name="w" type="hidden" value="1">
								<input name="keyword" type="text" class="joblist_search_box_text" placeholder="请输入职位关键字">
								<input name="" type="submit" class="joblist_search_bth" value=" ">
							</div>
						</form>
					</div>

					<iframe id="supportiframe"  name="supportiframe" onload="returnmessage('supportiframe');" style="display:none"></iframe>
					<form action="index.php?c=job&act=opera" target="supportiframe" method="post" id='myform' >
					
					<div class="clear"></div>
					{yun:}foreach item=job from=$rows{/yun}
					<div class="yun_m_joblist">
						
						<div class="yun_m_joblistcheckboxbox">
							<input type="checkbox" name="checkboxid[]" value="{yun:}$job.id{/yun}" class="com_job_list_check">
						</div>

						<div class="yun_m_jobname"> 
							<a href="{yun:}url m=job c=comapply id='`$job.id`'{/yun}" class="yun_m_jobname_a" target="_blank">{yun:}$job.name{/yun}</a> 
							<i class="job_share">
								<div class="job_share_img" style="display:none">
									<img src="{yun:}url m=job c=comapply a=qrcode id=$job.id{/yun}" width="130" height="130"/>
								</div>
							</i> 
						</div>

						<div class="yun_m_joblist_left">
							<div class="yun_m_joblist_left_p"> 
								状态：<span class="yun_m_joblist_left_zt">招聘中</span> 
								<span class="yun_m_joblist_left_eye">被浏览：{yun:}$job.jobhits{/yun}</span> 
							</div>
							<div class="yun_m_joblist_left_p"> 
								应聘简历：{yun:}$job.jobnum{/yun} <a href="index.php?c=hr&jobid={yun:}$job.id{/yun}-{yun:}$job.type{/yun}">查看</a> 
							</div>
							<div class="yun_m_joblist_left_p"> 到期时间：{yun:}$job.edate|date_format:'%Y-%m-%d'{/yun} </div>
                            
						</div>
	<div class="yun_m_joblist_gxtime"> 更新日期{yun:}$job.lastupdate|date_format:'%Y-%m-%d'{/yun} </div>
						<div class="yun_m_joblist_cont">

							<div class="yun_m_joblist_extension {yun:}if $job.rec_time>time() && $job.rec==1{/yun}yun_m_joblist_extension_cur{yun:}/if{/yun} yun_m_joblist_extension_cur_hov" dtype="rec" pid="{yun:}$job.id{/yun}"> 
								<i class="yun_m_joblist_extension_icon"></i>
								<i class="yun_m_joblist_tip_icon"></i>
								<div class="yun_m_joblist_extension_p">推荐</div>
								<a href="javascript:void(0);" onclick="rec('{yun:}$job.id{/yun}','{yun:}if $job.rec=='1' &&  $job.rec_time>time(){/yun}{yun:}$job.rec_time|date_format:'%Y-%m-%d'{/yun}{yun:}else{/yun}0{yun:}/if{/yun}')" class="yun_m_joblist_extension_bth"></a> 
							</div>

							<div class="yun_m_joblist_extension {yun:}if $job.urgent_time>time() && $job.urgent==1{/yun} yun_m_joblist_extension_cur{yun:}/if{/yun}" dtype="urgent" pid="{yun:}$job.id{/yun}"> 
								<i class="yun_m_joblist_extension_icon yun_m_joblist_extension_icon_urgent"></i> 
								<i class="yun_m_joblist_tip_icon"></i>
								<div class="yun_m_joblist_extension_p">紧急</div>
								<a href="javascript:void(0);" onclick="urgent('{yun:}$job.id{/yun}','{yun:}if $job.urgent=='1' && $job.urgent_time > time() {/yun}{yun:}$job.urgent_time|date_format:'%Y-%m-%d'{/yun}{yun:}else{/yun}0{yun:}/if{/yun}')" class="yun_m_joblist_extension_bth"></a> 
							</div>

							<div class="yun_m_joblist_extension {yun:}if $job.xsdate>time() && $job.xsdate{/yun}yun_m_joblist_extension_cur{yun:}/if{/yun}" dtype="jingjia" pid="{yun:}$job.id{/yun}"> 
								<i class="yun_m_joblist_extension_icon yun_m_joblist_extension_icon_zd"></i> 
								<i class="yun_m_joblist_tip_icon"></i>
								<div class="yun_m_joblist_extension_p">置顶</div>
								<a href="javascript:void(0);" onclick="jingjia('{yun:}$job.id{/yun}','{yun:}if $job.xs=='1' && $job.xsdate>time(){/yun}{yun:}$job.xsdate|date_format:'%Y-%m-%d'{/yun}{yun:}else{/yun}0{yun:}/if{/yun}');" class="yun_m_joblist_extension_bth"></a> 
							</div>

							

							<div class="yun_m_joblist_extension {yun:}if $job.autotime>time(){/yun}yun_m_joblist_extension_cur{yun:}/if{/yun}" dtype="autojob" pid="{yun:}$job.id{/yun}"> 
								<i class="yun_m_joblist_extension_icon yun_m_joblist_extension_icon_sx"></i> 
								<i class="yun_m_joblist_tip_icon"></i>
								<div class="yun_m_joblist_extension_p">自动刷新</div>
								<a href="javascript:void(0);" onclick="autojobs('','{yun:}$job.id{/yun}','{yun:}if $job.autotime>time(){/yun}{yun:}$job.autodate{/yun}{yun:}/if{/yun}');" class="yun_m_joblist_extension_bth"></a> 
							</div>

							<div class="yun_m_joblist_tip" id="tip{yun:}$job.id{/yun}">职位推荐，让你更快找到满意人才</div>

						</div>
						
						<div class="yun_m_joblist_right"> 
							<a href="javascript:void(0);" onclick="gotime('{yun:}$job.id{/yun}','{yun:}$job.edate|date_format:'%Y-%m-%d'{/yun}')"  class="yun_m_joblist_right_a">延期</a> 
							
							<a href="javascript:void(0)" onclick="refreshJob('{yun:}$job.id{/yun}');" class="yun_m_joblist_right_a">刷新</a> 
							
							{yun:}if $job.status=="1"{/yun} 
								<a href="javascript:onstatus('{yun:}$job.id{/yun}','2');" class="yun_m_joblist_right_a">上架</a> 
							{yun:}else{/yun} 
								<a href="javascript:onstatus('{yun:}$job.id{/yun}','1');"  class="yun_m_joblist_right_a">下架</a> 
							{yun:}/if{/yun} 
							
							<a href="{yun:}url m=job c=comapply id='`$job.id`'{/yun}" target="_blank" title="预览"class="yun_m_joblist_right_a">预览</a> 
							
							<a href="index.php?c=jobadd&act=edit&id={yun:}$job.id{/yun}" class="yun_m_joblist_right_a">修改</a> 
							
							<a href="javascript:void(0)" onclick="layer_del('确定要删除该职位？', 'index.php?c=job&act=opera&del={yun:}$job.id{/yun}');" class="yun_m_joblist_right_a">删除</a>
							
							<div class="yun_m_joblist_right_resume"> 
								<a href="index.php?c=likeresume&jobid={yun:}$job.id{/yun}"> 自动匹配简历>></a> 
							</div>
						</div>
					</div>


					{yun:}foreachelse{/yun}
						<div class="com_msg_no">
							<p>亲爱的用户，目前您还没有招聘中的职位信息</p>
							<a href="javascript:;" onclick="jobadd_url('{yun:}$addjobnum{/yun}','{yun:}$config.integral_job{/yun}');"  class="com_msg_no_bth com_submit">发布职位</a> 
						</div>
		            {yun:}/foreach{/yun} 
            
					{yun:}if !empty($rows){/yun}
						<div class="com_Release_job_bot mt10"> 
							<span class="com_Release_job_qx">
								<input id='checkAll' type="checkbox" onclick='m_checkAll(this.form)' class="com_Release_job_qx_check">全选
							</span>

							<input class="c_btn_02 c_btn_02_w110" type="button" value="批量延长有效期" onclick="allgotime();">
							<input class="c_btn_02 c_btn_02_w110" type="button" value="批量自动刷新" onclick="return autojobs('checkboxid[]');">
							<input class="c_btn_02 c_btn_02_w110" type="button" value="批量刷新职位" onclick="return RefreshSelectJob('checkboxid[]');">
							<input class="c_btn_02 c_btn_02_w110" type="button" value="一键下架招聘" onclick="return allonstatus('checkboxid[]');">
							<input class="c_btn_02 c_btn_02_w110" type="button" value="批量删除职位" onclick="return really('checkboxid[]');">
						</div>
						<input type="hidden" id="autodj" value="{yun:}$config.job_auto{/yun}"/>
						<input type="hidden" id="sxdj" value="{yun:}$config.integral_jobefresh{/yun}"/>
						<input type="hidden" id="refreshjobids" value=""/>
						<input type="hidden" id="breakjob_num" value="{yun:}$statis.breakjob_num{/yun}"/>
					{yun:}/if{/yun}
					</form>
				</div>

				<div class="clear"></div>
				<div class="diggg">{yun:}$pagenav{/yun}</div>
         
				<div class="wxts_box wxts_box_mt30">
					<div class="wxts">温馨提示：</div>
					1、 贵公司还可以发布（<span class="f60">{yun:}if $statis.vip_etime>time()||$statis.vip_etime=="0"{/yun}{yun:}if $statis.rating_type==1{/yun}{yun:}$statis.job_num{/yun}{yun:}else{/yun}不限{yun:}/if{/yun}{yun:}else{/yun}0{yun:}/if{/yun}</span>）条职位信息<br>
					2、如贵公司要快速招聘人才，建议成为我们的会员，获取更多的展示机会，以帮助您快速找到满意的人才。<a href="index.php?c=right" class="wxts_sj">立即升级</a> <br>
					3、请贵公司保证职位信息的真实性、合法性，并及时更新职位信息，如被举报或投诉，确认发布的信息违反相关规定后，本站将会关闭贵公司的招聘服务，敬请谅解！ <br>
					4、参加紧急的招聘职位;我们将在首页紧急招聘 模块显示，并有紧急图标显示。<br>
					5、参加自动刷新的招聘职位;使招聘职位信息置于列表前端，更有利于吸引客户的注意<br>
					6、参加置顶服务的招聘职位；我们将在首页列表模块显示 ！ 
				</div>
			</div>
		</div>
	</div>
</div>
<script>
function gotime(id,edate,i){
	$("#gotimeid").val(id);
	if(i){
		$("#gotime_edate").html("本次共延期<font color='red'>"+i+"</font>个职位！"); 
	}else{
		$("#gotime_edate").html('当前职位到期时间：<font color="red">'+edate+'</font>');
	}
	$.layer({
		type : 1,
 		title : '延期天数',
		closeBtn : [0 , true],
		border : [10 , 0.3 , '#000', true],
		area : ['340px','210px'],
 		page : {dom : '#gotime'}
	});
}
function allgotime(){//批量延期
	var allid =[];
	var i=0;
	$('input[name="checkboxid[]"]:checked').each(function(){
		allid.push($(this).val());
		i++;
	});
	if(allid.length==0){
		layer.msg("请选择要延期的职位！",2,8);return false;
	}else{
		gotime(allid,'',i);	
	}
}
function allonstatus(){//批量延期
	var allid =[];
	var i=0;
	$('input[name="checkboxid[]"]:checked').each(function(){
		allid.push($(this).val());
		i++;
	});
	if(allid.length==0){
		layer.msg("请选择要下架的职位！",2,8);return false;
	}else{
		onstatus(allid,1);
	}
}
function onstatus(id,status){//修改招聘状态
	$.post("index.php?c=job&act=opera",{id:id,status:status},function(data){
		if(data==1){ 
			layer.msg('设置成功！', 2, 9,function(){window.location.reload();});return false;
		}else{
			layer.msg('设置失败！', 2, 8);
		}
	})
}

$(document).ready(function(){
	$(".job_share").hover(function(){
		
		var html=$(this).find('.job_share_img').html();
		layer.tips(html, this, {
			guide: 1,
			style: ['background-color:#5EA7DC;', '#5EA7DC']
		});
		$(".xubox_layer").addClass("xubox_tips_border");
	},function(){layer.closeTips();}); 
		
	$(".job_list_extension_box").hover(function(){
		$(this).find('.job_list_extension_box_list').show();
	},function(){
		$(this).find('.job_list_extension_box_list').hide();
	}) 
	$(".job_tck_list").click(function(){
		var cron = $(this).attr('data-cron');
		var name = $(this).attr('data-name');
		$("#autotype").val(cron);
		$(".job_box_in").html(name);
		$(".job_tck_box_pot").hide();
	});
	$(".job_box_in").click(function(e){
		$(".job_tck_box_pot").toggle();
	});
	$(document).bind("click",function(e){
		if(e.target.className != 'job_box_in'){
			$(".job_tck_box_pot").hide();
		}
	}); 
	$('.yun_m_joblist_extension').hover(function() {
		var type=$(this).attr('dtype');
		var pid=$(this).attr('pid');
		$('.yun_m_joblist_extension').removeClass('yun_m_joblist_extension_cur_hov');
		$(this).addClass('yun_m_joblist_extension_cur_hov');
		if(type=='rec'){
			$('#tip'+pid).html('职位推荐，让你更快找到满意人才');
		}else if(type=='urgent'){
			$('#tip'+pid).html('紧急招聘，让你更快找到满意人才');
		}else if(type=='jingjia'){
			$('#tip'+pid).html('职位置顶，让你更快找到满意人才');
		}else if(type=='autojob'){
			$('#tip'+pid).html('自动刷新，让你更快找到满意人才');
		}
	});
});
</script> 
<!--延期天数弹出框-->
<div id="gotime"  style="display:none; width:230px; ">
  <div class="job_box_div"   style="width:300px; ">
    <div class="job_box_msg" style="margin-left:10px;_margin-left:5px;padding:5px;">
      <p id="gotime_edate"></p>
    </div>
    <form action='index.php?c=job&act=opera' target="supportiframe" method="post" id='gotimef'>
      <input type="hidden" name="gotimeid" id="gotimeid" value=""/>
      <div class="job_box_inp"  style="padding:10px 5px 5px 20px"> <span style="float:left; margin-right:0px;">延期天数：</span>
        <input name="day" value="" class="com_info_text placeholder" type="text" onkeyup="this.value=this.value.replace(/[^0-9]/g,'')" style="width:100px; float:left"/>
        <span class="fltL box_infobox_span" style="padding-left:10px; line-height:40px;">天</span> </div>
      <span class="job_box_botton" style="width:100%;"> <a class="job_box_yes job_box_botton2" href="javascript:void(0);" onclick="$('#gotimef').submit();">确定</a> </span>
    </form>
  </div>
</div>
<!--延期天数弹出框end--> 
{yun:}include file="$comstyle/jobserver.htm"{/yun}
{yun:}include file="$comstyle/com_tc_server.htm"{/yun}
{yun:}include file="$comstyle/footer.htm"{/yun}